home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
EnigmA Amiga Run 1996 June
/
EnigmA AMIGA RUN 08 (1996)(G.R. Edizioni)(IT)[!][issue 1996-06][EARSAN CD VII].iso
/
earcd
/
comm1
/
cnetwho.lha
/
who
/
Long
< prev
next >
Wrap
Text File
|
1996-05-08
|
14KB
|
141 lines
/**************************************************************************\
$VER: CNet Long WHO, v2.61 (8-May-96) by Dotoran!
\**************************************************************************/
options results;signal on SYNTAX;signal on ERROR;signal on IOERR
tr=transmit;se=sendstring;gu=getuser;gs=getscratch;gc=getchar;mg=maygetchar
a='rexxsupport.library';if ~show('l',a) then if ~addlib(a,0,-30) then exit
gu 1311992;dp=result;changewhere 'Long WHO';gu 39;uucp=result;mdir="mail:users/"uucp"/"
glimpse=mdir"_Glimpse";glimpse2=dp"_Glimpse"
banners=mdir"_Banners";banners2=dp"_Banners"
history=mdir"_History";history2=dp"_History"
low=0;gu 2225094;high=result;gu 23;myport=result;gu 1100660;a=result;mci1=BitTST(d2c(a,4),0);mci2=BitTST(d2c(a,4),1)
pd=2424286;gu 55;help=result;gu 2107337;idle=result;gu 1100663;sysop=BitTST(d2c(result,4),4)
gu 1100661;conf=BitTST(d2c(result,4),7);call CONFIG;quick=0;gu 1302307;arg=upper(result);args=low'-'high
if arg>''&index('CIEQ?BGVHP',left(arg,1))=0 then call ARGS;arg=left(arg,1);tot=high;call PARSER(args,0,high);if totpit=0 then arg='?'
helpT='n1cfLong Whoc6, vcb2c6.cb60 c6by cdDotorann2Cc7Formatsce: '
if conf=1 then do;helpT=helpT'caWHO c7[c6<ceCc6>ceonfigc7] c6--- c9Conference Controllers cfONLYc9!n1'
helpT=helpT'CcaWHO c7[c6<ceIc6>cedle Loaderc7] c6--- c9Conference Controllers cfONLYc9!n1'
helpT=helpT'CcaWHO c7[c6<ceEc6>cedit Idlesc7] c6--- c9Conference Controllers cfONLYc9!n1';end
helpT=helpT'CcaWHO c7[c6<ceQc6>ceuick Listc7]n1CcaWHO c7[c6<cePc6>ceort Bannerc7]n1'
helpT=helpT'CcaWHO c7[c6<ceBc6>ceannersc7]n1CcaWHO c7[c6<ceGc6>celimpsec7]n1'
helpT=helpT'CcaWHO c7[c6<ceVc6>ceiew c6<caHc6>caistoryc7]n1'
helpT=helpT'CcaWHO c7[c6portce# c6pce#cb-c6pce# c6pce#cb,c6pce# cb-c6pce# c6pce#cb-c7] cbetcc6...'
v1=1;v2=1;v3=1;v4=0;v5=0;v6=0;loS=0;hiSk=0;v7=1;v8=1;v9=0;if v7=1&index('CIE?BGVHP',arg)=0 then tr 'f1'
if arg='B' then signal AB;if arg='G' then signal AG;if arg='V'|arg='H' then signal AV
if arg='?' then do;tr helpT;exit;end;if v7=1&arg='C'&conf~=1 then tr 'f1'
if arg='C'&conf=1 then do;se 'n1c3Loading z4c7LONGz0 c3who config...';tr '#0'dp'Config}';exit;end;if getclip('IdleWhoB0')='' then se '#0'dp'Loader}'
if arg='I'&conf=1 then do;se 'n1ceReLoading cbIdle cfPort c9Bannersc6...';call setclip('IdleWhoB0');tr '#0'dp'Loader}cdDonec6!';exit;end
if arg='Q' then quick=1;if arg='P' then do;a=getclip('IdleWhoB'myport);tr 'n1c6Port cb'myport'c9: ca'a'n1';exit;end
if arg='E'&conf=1 then do;loadeditor dp'IdlePorts';tr 'n1ceEdit cb"caIdlePortscb" c6file...';calleditor 102;gu 1109865
st=result;if st=1 then do;se 'cfSaving cb"caIdlePortscb" c6file...';saveeditor dp'IdlePorts';tr 'cdDonec6!';end
else if st=0 then do;se 'c9Delete cb"caIdlePortscb" c6file? c7[caYesc7]c6: ca'
gc;a=result;if a='N' then tr 'No.';else do;se 'Yesc6! c9Deletingc6...'
address command 'delete 'dp'IdlePorts';tr 'cdDonec6!';end;end;exit;end
START:;tr "z6c4Portz0 z6c4User Handle z0 z6c4Logon z0 z6c4Spdz0 z6c4From z0 z6c4Where z0";call MGC
tr 'cc==== ==================== ====== === ======================== ================='
do ii=1 to totpit;i=subword(it.0,ii,1);if index(' 'it.0' ',i)=0 then iterate ii
if v6=1&ii=loS+1 then do;ii=hiSk-1;iterate ii;end;port=i;st=' ';gu 1101630+i;a=d2c(result);call MGC
mu=BitTST(a,1);if mu=1 then st='m';hi=BitTST(a,0);if hi=1&myport~=i then st='h'
getportid i;id=result;getwhere i;where=left(result,17);gu pd+(i*4);zy=c2d(import(offset(null(),result+30),2))
call MINUTES(zy);iT=zz;if where='(offline)' then iterate ii;if id=-1&(idle=1|v4=1) then iterate ii
off=1630+myport;gu pd+(i*4);hidden=result+off;hide=BitTST(import(offset(null(),hidden),1),0)
muff=BitTST(import(offset(null(),hidden),1),1);gu 1200032;a=result;if hide=1&conf~=1 then do;a=a+fake;id=-1;call MINUTES(a);iT=zz;end
call MGC;if hide=1&conf~=1&v5=1 then iterate ii;if id>-1 then do;loadscratch id;savescratch (-id);gs 1101333
con=BitTST(d2c(result,4),7);if con=1&myport~=i then st='+';if muff=1&con=0&st~='h' then st='M'
if hide=1&con=0 then st='H';if v1=1&zy>5 then where='c9Idle cb'iT;else where=where'cfcf'
gs 1;handle=result;gs 1201214;cps=result%10;gs 4;city=result;gs 56;country=result
gs 57;logon=right(result,6);gs 38;who=result;gs 11;date=substr(result,5,6);gs 1101133;gender=result
sex='z4cf Male z0';if result=0 then sex='z1cb Female z0';gs 18;time=result%10;gs 39;udir=result
his=exists("mail:users/"udir"/_History");call MGC;end
else do;handle=l903;where=l107;cps=0;city='';country='';logon='';a='';who=''
time=0;if v1=1&where=l107 then where='c9Idle cb'iT;if v2=1 then a=getclip('IdleWhoB'i)
if a='' then a=getclip('IdleWhoBD');call MGC;end;if id>-1|a='' then do
se 'cf'right(port,2)' cb'st' ce'handle'.26}cd'right(logon,6)
se ' cb'right(cps,3)' c6'left(city,21)left(country,3)' c9';tr where'ca';call MGC;end
else do;tr 'cf'right(port,2)' cb'st' 'a'.62}c9'where;call MGC;end
if id~=-1 then do;se 'z6c4 LC z0cf: ca'date' 'sex' cb'substr(' *',his+1,1)
tr 'z6c4 TT z0cf: c9'left(time,8)'@8ca'left(who,42)'cd';call MGC;end
if exists("mail:users/"udir"/_Glimpse")&id~=-1&quick=0 then do;sendfile "mail:users/"udir"/_Glimpse";call MGC;end
if ~exists("mail:users/"udir"/_Glimpse")&id~=-1&quick=0 then do;sendfile glimpse2;call MGC;end
if totpit>1&ii~=totpit&quick=0 then tr 'c6'copies('-',79)''
end ii;se 'cc'copies('=',79)'';call MGC;if help=3|quick=1 then signal MENU
if help=2 then do;se 'n1z6c4 LC z0cf=caLast Callcf, cb*cf=cbHistorycf, '
se 'z6c4 TT z0cf=c9Time Todaycf, cbmcf=cbMuffledcf, ';tr 'cbhcf=cbHiddencf, cb+cf=cbConf. Cont.';signal MENU;end
tr "n1 cbm cc= cdYou're Muffling this Port. cbh cc= ceYou're Hiding from this Port.";call MGC
if conf=1 then tr " cbM cc= caThey're trying to Muffle You. cbH cc= caThey're trying to Hide from You."
tr "z6c4 LC z0cc = caUser's Last Call Date. z6c4 TT z0cc = cdTime Used Today by this User."
tr " cb* cc= cdThis User has a HISTORY File. cb+ cc= ceUser has Conference Control.";call MGC
MENU:;if quick=1 then exit;se 'n1c6Long cbWho c7[caBc7]caannerc6, c7[caGc7]calimpsec6, '
se 'c7[caVc7]caiew cfHistoryc6, or c7[cdQUITc7]c6: ca';gc;a=index('BGVHQ',result)
if a=0|a=5 then do;tr 'cdQuit';exit;end;if a=1 then do;tr 'Banner'
AB:;gu 38;banner=result;b.0=banner;save=0
if v3=0&conf~=1 then do;tr 'n1c6You can c9NOT cfcreate ceMultiple cdWho Bannersc6! Use cfEP;14 c6instead!';signal MENU;end
if ~exists(banners) then do;address command "copy "banners2" "banners;end
call open(f1,banners,'r');do i=1 to 9;b.i=readln(f1);end i;call close(f1)
E0:;tr 'f1n1c9r1 Your Short Who Banners r0n2ce Current Bannern1ca~~~~~~~~~~~~~~~~n1cdBanner cb0ca: @8ce'b.0
tr 'n1ce Banners On Filen1ca~~~~~~~~~~~~~~~~~';do i=1 to 9;tr 'cdBanner cb'i'ca: @8ce'b.i;end i
se 'n1c6Edit c7[ca0c7] c6thru c7[ca9c7]c6, c7[cdQc7]cduitc6, or c7[caPc7]caick c6current? c7[caPickc7]c6: ca'
gc;a=index('0123456789PQ',result);if result='###PANIC' then exit;else if a=0 then a=11
if a=12 then do;tr 'cdQuit';signal MENU;end;if a<11 then do;a=a-1;tr a
E1:;addkeys (b.a);se 'n1c6Edit cdBanner cb'a'ca:cfi'128+v8*256' 42}';gu 70;ban=result
if index(ban,"") then do;tr "c9Control-Q characters are PROHIBITED in Banners!";b.a=ban;signal E1;end
if sysop=0|(sysop=1&v9=0) then do;ban2=ban;call STRIPSMCI;if ban2~=ban then tr "c9SysOp Only MCI's have been REMOVED! c7<ccKeyc7>g1";end
if mci1=0|mci2=0 then do;ban2=ban;call STRIPMCI2;if ban2~=ban then tr "c9Level 2 MCI's have been REMOVED! c7<ccKeyc7>g1";end
if mci1+mci2=0 then do;ban2=ban;call STRIPMCI;if ban2~=ban then tr "c9ALL MCI Occurances have been REMOVED! c7<ccKeyc7>g1";end
se 'n1c6Is cb"@8ce'ban'cb" c6Correct? c7[caYesc7]c6: ca';gc;c=result;if c='N' then do;tr 'No.';b.a=ban;signal E1;end
tr 'Yes!';b.a=ban;save=1;if a=0 then save=2;signal E2;end
if a=11 then do;se 'Pickn2c6Use which cdBanner c6as cfCurrentc6? c7[ce<ca1ce>c7-ca9c7]c6: ca'
gc;a=index('123456789',result);if a<1 then a=1;tr a;b=b.0;b.0=b.a;b.a='';do i=1 to 9;j=i+1
if b.i='' then do;b.i=b.j;b.j='';end;end i;b.9=b;save=2;end
E2:;if save=2 then do;setobject b.0;putuser 38;end;if save>0 then do;call open(f1,banners,'w');do i=1 to 9
call writeln(f1,b.i);end i;call close(f1);save=0;end;signal E0;end;if a=2 then do;tr 'Glimpse'
AG:;tr 'n1c6You''ll have cb3 c6lines to cfcreate c6and/or cdedit c6your cb"caGlimpsecb"c6 file...'
cleareditor;if exists(glimpse) then loadeditor glimpse;calleditor 3;gu 1109865;st=result;if exists(glimpse)&st=0 then do
se 'c9Delete c6your cb"caGlimpsecb"c6 file now? c7[caYesc7]c6: ca';gc;a=result
if a='N' then do;tr 'No.';signal MENU;end;else do;tr 'Yes!';address command 'delete 'glimpse
signal START;end;end;if st=1 then saveeditor glimpse;signal START;end;if a=3|a=4 then do;tr 'View History'
AV:;se 'n1c7[caEc7]caditc6, c7[caVc7]caiew c6by cbPortc6, or c7[caSc7]capecific cfHistoriesc6? c7[cdQUITc7]c6: ca'
gc;a=index('EVPSHQ',result);if a=0|a=6 then do;tr 'cdQuit';signal MENU;end
if a=1 then do;tr 'Edit';tr 'n1c6You''ll have cb20 c6lines to cfcreate c6and/or cdedit c6your cb"caHistorycb"c6 file...'
if exists(history) then loadeditor history;else cleareditor;calleditor 20;gu 1109865;st=result;if exists(history)&st=0 then do
se 'c9Delete c6your cb"caHistorycb"c6 file now? c7[caYesc7]c6: ca';gc;a=result
if a='N' then do;tr 'No.';signal MENU;end;else do;tr 'Yes!';address command 'delete 'history;signal START;end;end
if st=1 then saveeditor history;signal START;end;if a=2|a=3 then do;tr 'View By Port'
VPM:;se 'n1 caView c6the cfHistory File c6for the cdUser c6on which cbPortc6? c7'right('[ca'myport'c7]',10)'c6:cai192 2}'
gu 70;p=result;if p='' then p=myport;getportid p;id2=result;if id2=-1 then do;getwhere p;a=result
if a='(offline)' then do;tr 'n1c6That cbPort c6is c9NOT c6Loaded!';signal MENU;end
if a=l107 then do;tr 'n1c9No One c6is caUSING c6that cbPort c6now!';signal MENU;end;end
loadscratch id2;savescratch (-id2);gs 1;han=result;gs 39;udir=result
VPA:;tr 'f1cer1'center('History File For "'han'" on Port 'p'...',78)'r0ca'
if ~exists("mail:users/"udir"/_History") then sendfile history2;else sendfile "mail:users/"udir"/_History"
se 'cc'copies('=',78)' n1c7[caVc7]caiew cbAnotherc6, c7[caRc7]caeView c6this cfHistoryc6, c7[caWc7]caho caListc6, or c7[cdQUITc7]c6: ca'
gc;a=index('VARHWLQ',result);if a=0|a=7 then do;tr 'cdQuit';exit;end;if a=1|a=2 then do;tr 'View Another';signal VPM;end
if a=3|a=4 then do;se 'ReView History';signal VPA;end;tr 'WHO Againn1';signal START;end;if a=4|a=5 then do;tr 'View Specific'
VSM:;se 'n1c6Enter cfID#c6, ceHandlec6, or cbReal Name c6to caViewc6: c7[ca1c7]c6: cai144 25}'
gu 70;hid=result;if hid='' then hid=1;findaccount hid;st=result;if st=0 then do
tr 'n1c9This is an Invalid Account! c6Check your typing.';signal MENU;end;loadscratch st;savescratch (-st)
gs 1;han=result;gs 4;city=result;gs 39;udir=result
VSA:;tr 'f1cer1'center('History File For "'han'" from 'city'...',78)'r0ca'
if ~exists("mail:users/"udir"/_History") then sendfile history2;else sendfile "mail:users/"udir"/_History"
se 'cc'copies('=',78)' n1c7[caVc7]caiew cbAnotherc6, c7[caRc7]caeView c6this cfHistoryc6, c7[caWc7]caho ceListc6, or c7[cdQUITc7]c6: ca'
gc;a=index('VARHWLQ',result);if a=0|a=7 then do;tr 'cdQuit';exit;end;if a=1|a=2 then do;tr 'View Another';signal VSM;end
if a=3|a=4 then do;se 'ReView History';signal VSA;end;tr 'WHO Againn1';signal START;end
MGC:;mg;if result='NOCHAR' then return;else do;tr l1066;exit;end
ARGS:;gu 1202244;total=result-1;args='';do i=0 to total+1;gu 1302307+(i*61);args=args||result' ';end i;return
PARSER:;arg rng,min,max;it.='';c=0;it=translate(rng,' ','.,');do a=1 to words(it);c=c+1;it.c=word(it,a)
if index(it.c,'-')>0 then do;parse var it.c x'-'y;if y='' then y=max;if x='' then x=min;if x>y then do;d=x;x=y;y=d;end
if x<min|y>max|~datatype(x,'W')|~datatype(y,'W') then do;c=c-1;iterate;end;do b=x to y;it.c=b;c=c+1;end;c=c-1;end
else if it.c<min|it.c>max|~datatype(it.c,'W') then do;c=c-1;iterate;end;end;totpit=c;do i=1 to c;it.0=it.0||it.i' ';end;return
MINUTES:;arg m;t=right(m,1);m=m%10;hrs=m%60;mins=m-(hrs*60);if hrs=0 then zz=mins'.'t' caMinutes';else zz=hrs'.'mins%6' cdHours';return
STRIPMCI:;do until z=0;z=index(ban,"");if z>0 then ban=delstr(ban,z,3);end;return ban
STRIPMCI2:;do i=1 to length(l5);zz=""upper(substr(l5,i,1));do until z=0;z=index(upper(ban),zz);if z>0 then ban=delstr(ban,z,3);end;end i;return ban
STRIPSMCI:;do i=1 to length(l4);zz=""upper(substr(l4,i,1));do until z=0;z=index(upper(ban),zz);if z>0 then ban=delstr(ban,z,3);end;end i;return ban
CONFIG:;call open(f1,dp'config.data','r');a=readln(f1);call close(f1);parse var a l107''l903''l1066''fake''l5''l4''j;return
SYNTAX:;ERROR:;IOERR:;e1=' Error: 'rc' ('errortext(rc)')';e2=' Line: 'left(sigl,4)'File:';gu 1311992;a=result
gu 1311960;b=result;c='"'a||b'"';e2=e2' 'c;tr e1;tr e2;logentry e1;logentry e2;e=sourceline(sigl)
do while e~='';e3='Source: 'left(e,37);tr e3;logentry e3;e=substr(e,38);end;bufferflush
/** Last Edited: 8-May-96 *************************************************\
\****************************************** Frontiers BBS (716)/823-9892 **/